package com.albaba.designpattern.state_pattern.text_001;

/**
 * @Description: TODO
 * @Author zx
 * @Date 2025/2/25 15:38
 * @Version 1.0
 */
public class Client {
    public static void main(String[] args) {
        Context context = new Context();
        State state1 = new ConcreteStateA();
        state1.hanld(context);
        System.out.println(context.getCurrentState().toString());
        System.out.println("==================================");
        State state2 = new ConcreteStateB();
        state2.hanld(context);
        System.out.println(context.getCurrentState().toString());

    }
}
